package cn.t222.mapper;

import cn.t222.pojo.Product;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;
import org.springframework.stereotype.Component;

import java.util.List;

@Component
public interface ProductRepository extends ElasticsearchRepository<Product, Long> {
    Product findByName(String name);
    List<Product> findByPriceBetween(double price1, double price2);
}
